In the past, when conducting inline high-speed scans of WEB (continuous objects: film, paper, sheet metal) and BATCH (sheet products, individual products: cut film, cut glass, drums), which are the objects to be scanned, scans for surface defects were conducted by using line sensor cameras, incorporating the surface of the flowing work pieces as continuous image data, and, with an image data processor, detecting areas that differ in brightness.
At that time, in order to precisely detect surface faults, it was necessary to illuminate uniformly with a fixed illumination intensity the area targeted for photography by said camera, and conventionally halogen lamps and fluorescent lights were used as the light irradiation devices for this purpose. Moreover, devices using LEDs that are superior in velocity responsiveness, stability of light intensity, and lifetime, etc. have recently been developed as a substitute for these light sources.
In this regard, even though illumined uniformly without unevenness on the area targeted for photography, the brightness level of the photographed image is higher in the central part and increasingly lower toward the edges because of lens aberration (distortion), or differences in the distance between the camera and the parts of the area targeted for photography or differences of image angle. In particular, this tendency is notable if using a wide-angle lens. Concretely, indicated in FIG. 15 is a depiction of video signals (signals of light received by a camera (CCD) converted to electronic signals), which are output from a camera.
Thus, in the past, after incorporating the image signals from the camera, the brightness of these signals was adjusted (shading compensation) on the image processor side by compensating on the signal level, for example, digitally, and scan processing was conducted thereafter. Typically, there are addition and subtraction devices that add brightness that is lacking to dark areas of the incorporated image that should have a fixed level of brightness, and subtract brightness from parts that are too bright; and there are devices that compensate the brightness of the various parts to a fixed level by gain control (multiplication). Further, there are a variety of methods that form the basis of compensation in these methods, as represented by Patent Literature (Japanese Unexamined Patent Application Publication No. H10-111251).
Nonetheless, when conducting shading compensation on the image processor side, there is the risk that image deterioration when converting the digital signals and differences in the calculation method during compensation may have a deleterious effect on the precision of detecting defects, etc. This will be explained by citing specific examples.
As indicated in FIG. 24, for example, the central part and the edge part in the width direction respectively have the same defect. Nonetheless, the brightness level that is entered as a signal for the defect at the edge is smaller because of the darkness.
When, for example, shading compensation is conducted from the image processor side with said addition and subtraction making the brightness levels of the whole uniform, as indicated in FIG. 25, a difference in those brightness levels may be generated because only the background is compensated and no changes are generated in the relative level of the defect from the background, irrespective of the central part and the edge having the same defect, and thus there is the specific risk of variance in the detection of defects. For example, if the threshold level of defect detection were set at the dotted line in this diagram, the defect on the edge would not be detected.
Meanwhile, if shading compensation is conducted from the image processor side with said gain control (multiplication) making the brightness levels of the whole uniform, as indicated in FIG. 26, the defect levels of the central part and the edge are uniform because both the background and the defect levels are compensated. However, gain control also amplifies noise near the edge, and produces the risk of mistakenly detecting this noise as a defect. For example, if the threshold level of defect detection were set at the dotted line in this diagram, the noise would be detected as a defect.
Further, because the load on the image processing side becomes larger, there is a resulting disadvantage that the scan time cannot be shortened without shortening the image processing time; and there is also the disadvantage that costs will increase if the scale of the image processor is increased. Moreover, there are devices that conduct the same kind of shading compensation on the photographic equipment side, but the same kinds of image deterioration, etc. can occur.